package cn.sheep.violet.utils

/**
  * author: old sheep
  * QQ: 64341393 
  * Created 2018/10/15
  */
object NBUtils {

    def str2Int(str:String) = {
        try {
            str.toInt
        } catch {
            case _: Exception => 0
        }
    }


    def str2Double(str:String) = {
        try {
            str.toDouble
        } catch {
            case _: Exception => 0d
        }
    }


}
